package com.aiobc.business.task;

import com.aiobc.business.common.service.BasicService;
import com.aiobc.common.core.constant.DictConstants;
import com.xxl.job.core.biz.model.ReturnT;
import com.xxl.job.core.handler.annotation.XxlJob;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * @Description TODO
 * @Date 2021/10/21
 * @Created by liqiang
 */
@Component
public class InitDictTask {
    @Autowired
    private BasicService basicService;

    @XxlJob("initDict")
    public ReturnT<String> initDict(String parm){
        basicService.loadSysDict();
        System.out.println(basicService.getListByTypeCode(DictConstants.DEVELOPER_TYPE).get(0).getDictLabel());
        return ReturnT.SUCCESS;
    }
}
